<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<%@page import="Retail.RetailProduct"%> 
<jsp:useBean id="a" scope="request" type="java.util.List"></jsp:useBean>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<form method="Post" action="/RetailSystem/ProductSelect">
		<input type="text" name="PID" value="">		
			<input type='submit'  value='Inquiry'> 		
</form>
<form method="Post" action="/RetailSystem/ProductUpdate">
<%
for (int i = 0; i < a.size(); i++) {

RetailProduct p = (RetailProduct) a.get(i);
%>
<p><%=p.getRProductID() %> </p>
<input type="hidden" name="ProductID" value="<%=p.getRProductID()%>">
<input type="text" name="ProductDesc" value="<%=p.getRProductDesc()%>">
<input type="text" name="ProductPrice" value="<%=p.getRProductPrice()%>"></br>
<input type="text" name="ProductCost" value="<%=p.getRProductCost()%>"></br>
<input type="text" name="ProductQuantity" value="<%=p.getRProductQuantity()%>"></br>
<input type="text" name="ProductVaildDate" value="<%=p.getRProductVaildDate()%>"></br>
<input type="text" name="ProductEntryDate" value="<%=p.getRProductEntryDate()%>"></br>


<%if ((i==a.size()-1)){ %>


<input type='submit'  value='Update'> 		

<% }%>
		
<% } %>
		

</form>

		
</body>
</html>